﻿using System;

namespace Borg
{
    [Serializable]
    public class Param : Qualifiable
    {
        private PlugType _plugType;
        private object _value;

        public PlugType PlugType
        {
            get { return _plugType; }
            internal set { _plugType = value; }
        }

        public object Value
        {
            get { return _value; }
            internal set { _value = value; }
        }

        public override bool IsQualified
        {
            get { return Qualifier.IsQualified(this); }
        }

        internal Param(int id, string name)
            : base(id, name)
        { }

        public override bool Qualify()
        {
            return Qualifier.Qualify(this);
        }

        internal override AssemblyElement GetAssemblyElement()
        {
            return PlugType.ExtensionType.Plugin;
        }
    }
}
